package cn.flexui.flexuiserver.domain.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * 支付信息表
 * </p>
 *
 * @author apeto
 * @since 2024-10-13 03:49:49
 */
@Getter
@Setter
@Accessors(chain = true)
@TableName("payment_info")
@Schema(name = "PaymentInfo", description = "支付信息表")
public class PaymentInfo extends BaseEntity {

    private static final long serialVersionUID = 1L;

    @Schema(description = "用户ID")
    @TableField("user_id")
    private Long userId;

    @Schema(description = "支付流水")
    @TableField("pay_sn")
    private String paySn;

    @Schema(description = "商品名称")
    @TableField("goods_name")
    private String goodsName;

    @Schema(description = "商品编码")
    @TableField("goods_code")
    private String goodsCode;

    @Schema(description = "商品类型: 10订阅")
    @TableField("goods_type")
    private Integer goodsType;

    @Schema(description = "三方支付流水")
    @TableField("out_pay_sn")
    private String outPaySn;

    @Schema(description = "支付金额")
    @TableField("pay_amount")
    private BigDecimal payAmount;

    @Schema(description = "支付状态 0: 支付中 1: 已支付 2: 支付失败 3: 支付取消")
    @TableField("pay_state")
    private Integer payState;

    @Schema(description = "支付类型")
    @TableField("pay_type")
    private String payType;

    @Schema(description = "商户号")
    @TableField("pay_merchant")
    private String payMerchant;

    @Schema(description = "备注")
    @TableField("remark")
    private String remark;

    @Schema(description = "支付时间")
    @TableField("pay_time")
    private Date payTime;
}
